package com.webchat.common.constants;

import lombok.AllArgsConstructor;
import lombok.Getter;

public class ResourceBehaviorConstants {


    @Getter
    @AllArgsConstructor
    public enum ResourceType {

        MOMENT("朋友圈动态"),
        ARTICLE("公众号文章"),
        SHOP_SKU("商城商品");
        private String typeName;
    }

    @Getter
    @AllArgsConstructor
    public enum BehaviorType {

        LIKE("点赞"),
        SHARE("分享"),
        VIEW("浏览"),
        COLLECT("收藏");

        private String typeName;
    }

    public static String getBehaviorTypeName(String behaviorTypeCode) {
        for (BehaviorType behaviorType : BehaviorType.values()) {
            if (behaviorType.name().equals(behaviorTypeCode)) {
                return behaviorType.getTypeName();
            }
        }
        return "";
    }
}
